From c289514fea64333674970a7c705950f526723985 Mon Sep 17 00:00:00 2001 From: Kenichi Handa Date: Tue, 28 Nov 2006 01:10:09 +0000 Subject: [PATCH] (regex_compile): Don't call SET_LIST_BIT with a multibyte character. --- src/regex.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/regex.c b/src/regex.c index 32991346399..7967a481ae9 100644 --- a/src/regex.c +++ b/src/regex.c @@ -2939,7 +2939,8 @@ regex_compile (pattern, size, syntax, bufp) for (ch = 0; ch < 1 << BYTEWIDTH; ++ch) { int translated = TRANSLATE (ch); - if (re_iswctype (btowc (ch), cc)) + if (translate < 1 << BYTEWIDTH + && re_iswctype (btowc (ch), cc)) SET_LIST_BIT (translated); } -- 2.30.2